package com.antwork.common.dao;

import com.antwork.common.entity.Pagination;
import java.io.Serializable;
import java.util.List;
import org.springframework.dao.DataAccessException;

public abstract interface GenericDao<T, PK extends Serializable> {
	public abstract void insert(T paramT);

	public abstract int update(T paramT);

	public abstract int update(DynamicSqlParameter paramDynamicSqlParameter);

	public abstract int delete(PK paramPK);

	public abstract int delete(DynamicSqlParameter paramDynamicSqlParameter);

	public abstract int truncate();

	public abstract int count();

	public abstract int count(DynamicSqlParameter paramDynamicSqlParameter);

	public abstract T get(PK paramPK);

	public abstract T load(PK paramPK) throws DataAccessException;

	public abstract List<T> select();

	public abstract List<T> select(DynamicSqlParameter paramDynamicSqlParameter);

	public abstract Pagination<T> selectPagination(
			DynamicSqlParameter paramDynamicSqlParameter);

	public abstract List<T> selectFk(
			DynamicSqlParameter paramDynamicSqlParameter);

	public abstract Pagination<T> selectFkPagination(
			DynamicSqlParameter paramDynamicSqlParameter);
}